package com.chris.core.socket.bio.run;

import com.chris.core.socket.bio.util.BioSokcetServerUtil;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.io.IOException;

public class BioServer {
    public static void main(String[] args) throws InterruptedException, IOException {
        BioSokcetServerUtil service = new BioSokcetServerUtil(10103,10000,300000,"") {
            Logger log = LoggerFactory.getLogger(this.getClass());

            @Override
            public void OnRevice(String sid, String mag) {
                log.debug("服务端->读取->客户端："+sid+"-->内容:" + mag);
            }

        };

        service.Open();


        Thread.sleep(10000);
        service.SendAllClientMsg("测试测试,我是服务端");

    }
}
